import common from "../common";
import constants from "../constants";

const baseCodeRulesApi = {
    findBaseCodeRules: (data, success, error) => {
        return common.requestData(constants.API_FindBaseCodeRules, data, success, error);
    },
    getBaseCodeRuleById: (data, success, error) => {
        return common.requestData(constants.API_GetBaseCodeRuleById, data, success, error);
    },
    saveBaseCodeRule: (data, success, error) => {
        return common.requestData(constants.API_SaveBaseCodeRule, data, success, error);
    },
    batchDeleteBaseCodeRule: (data, success, error) => {
        return common.requestData(constants.API_BatchDeleteBaseCodeRule, data, success, error);
    },
    getAutoOrderCode: (data, success, error) => {
        return common.requestData(constants.API_GetAutoOrderCode, data, success, error);
    },

    findBaseCodeRuleItems: (data, success, error) => {
        return common.requestData(constants.API_FindBaseCodeRuleItems, data, success, error);
    },
    batchSaveBaseCodeRuleItem: (data, success, error) => {
        return common.requestData(constants.API_BatchSaveBaseCodeRuleItem, data, success, error);
    },
    deleteBaseCodeRuleItem: (data, success, error) => {
        return common.requestData(constants.API_DeleteBaseCodeRuleItem, data, success, error);
    },
    batchDeleteBaseCodeRuleItem: (data, success, error) => {
        return common.requestData(constants.API_BatchDeleteBaseCodeRuleItem, data, success, error);
    },
};

export default baseCodeRulesApi;